home *** CD-ROM | disk | FTP | other *** search
- an empty String:
- A string initialized to Hello:Hello
- A string initialized to previous string:Hello
- A string initialized to previous string.at(1, 2):el
- A string initialized to @:@
- A string initialized to dec(20):20
- n = 20 atoi(n) = 20 atof(n) = 20
- z = x + y = Helloworld
- x += y; x = Helloworld
- y.prepend(x); y = Helloworld
- cat(x, y, x, x); x = HelloworldHello
- cat(y, x, x, x); x = worldHelloHello
- z = x + s + + y.at(w) + y.after(w) + . = Hello, world.
- ch = x[0] = H
- z = x.at(2, 3) = llo
- x.at(2, 2) = r; x = Hero
- x.at(0, 1) = j; x = jello
- x.at(He) = je; x = jello
- x.at(l, -1) = i; x = Helio
- z = x.at(r) = ello
- z = x.before(o) = Hell
- x.before(ll) = Bri; x = Brillo
- z = x.before(2) = He
- z = x.after(Hel) = lo
- x.after(Hel) = p; x = Help
- z = x.after(3) = o
- z = a bc; z = z.after(RXwhite); z =a bc
- x.gsub(l, ll); x = Hellllo
- x.gsub(r, ...); x = Hello should have been replaced by this string
- x.gsub(RXwhite, #); x = Hello#should#have#been#replaced#by#this#string
- z = x+y; z.del(loworl); z = Held
- reverse(x) = olleH
- x.reverse() = olleH
- upcase(x) = HELLO
- downcase(x) = hello
- capitalize(x) = Hello
- z = replicate(*, 10) = **********
- z = This string has
- five words
- from split(z, RXwhite, w, 10), n words = 5:
- This
- string
- has
- five
- words
- z = join(w, nw, /); z =This/string/has/five/words
- enter a word:word =abcdefghijklmnopqrstuvwxyz length = 26
-
- End of test
-